version: '3.8'

services:
  app:
    build:
      context: .
    volumes:
      - .:/app
    ports:
      - "80:80"
    depends_on:
      - db

  db:
    image: postgres:13
    env_file:
      - ./app/.env
    volumes:
      - postgres_data:/var/lib/postgresql/data
    ports:
      - "5432:5432"

volumes:
  postgres_data: